AddComponent<T, TState>(IContainer<TState>, int)

Method

Namespace: Ignis

Declared in: Ignis.IgnisExtensions


Adds a component to an existing entity.

Syntax

public static IContainer<TState> AddComponent<T, TState>(
	IContainer<TState> container,
	int entityId
)

Parameters

container

The ECS container

entityId

Entity ID for which the component should be attached

Returns

The ECS container

Type parameters

T

Type of the component

TState

Type of the state parameter passed to container


Back to index